<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<link type="text/css" rel="stylesheet" href="/${initParam.context_root }/css/admin/admin_tab_member.css">
<script type="text/javascript" src="/${ initParam.context_root }/script/jquery.js"></script>
<h1>${requestScope.divideText }</h1>
<h4>${requestScope.divideTextSub }</h4>
총 회원 수 : ${requestScope.pagingBean.totalContent }<br/>
<table id="content" border="1"  align="center">
	<tr>
		<th width="150px">id</th>
		<th width="150px">별명</th>
		<!-- <th width="100px">작성자</th> -->
		<th width="150px">지역</th>
		<th width="150px">가입일</th>
		<th width="100px">로그인</th>
	</tr>
	<c:forEach items="${requestScope.memberlist }" var="member">
		<tr>
			<td>${member.id }</td>
			<td><a href="/${initParam.context_root }/admin/login/getContent.do?id=${member.id }&page=${requestScope.pagingBean.currentPage}">${member.nickname }</a></td>
			<%-- <td>${cscenter.nickname }</td> --%>
			<td>${member.city } ${member.town }</td>
			<td>${member.joinDate }</td>
			<td><c:choose>
					<c:when test="${member.loginCheck=='1'}">On</c:when>
					<c:otherwise>Off</c:otherwise>
				</c:choose></td>
		</tr>
	</c:forEach>
</table>
<div align="center">
	<c:choose>
		<c:when test="${requestScope.pagingBean.previousPageGroup }">
			<a href="/${initParam.context_root }/admin/login/member_info.do?page=${requestScope.pagingBean.startPageOfPageGroup - 1}&role=${requestScope.role }">◀</a>
		</c:when>
		<c:otherwise>◀</c:otherwise>
	</c:choose>
	<c:forEach begin="${requestScope.pagingBean.startPageOfPageGroup }"
					end="${requestScope.pagingBean.endPageOfPageGroup }"
					step="1"
					var="i">
		<c:choose>
			<c:when test="${i == requestScope.pagingBean.currentPage }">
				${i }
			</c:when>
			<c:otherwise>
				<a href="/${initParam.context_root }/admin/login/member_info.do?page=${i}&role=${requestScope.role }">${i }</a>
			</c:otherwise>
		</c:choose>
	</c:forEach>
	<c:choose>
		<c:when test="${requestScope.pagingBean.nextPageGroup }">
			<a href="/${initParam.context_root }/admin/login/member_info.do?page=${requestScope.pagingBean.endPageOfPageGroup +1}&role=${requestScope.role }">▶</a>
		</c:when>
		<c:otherwise>▶</c:otherwise>
	</c:choose>
</div>
<c:if test="${requestScope.divide=='5' || requestScope.divide=='6'}">
	<div>
		<button onclick="javascript:window.location.href='/${initParam.context_root }/admin/cscenter/login/writeForm.do?divide=${requestScope.divide }&page=${requestScope.pagingBean.currentPage }'">글쓰기</button>
	</div>
</c:if>